package com.hdw.med.bean.model;

import java.io.Serializable;

public class BaseIndex implements Serializable {
    private static final long serialVersionUID = 1L;

    private String pk;

    private String cd;

    private String na;

    public String getPk() {
        return pk;
    }

    public void setPk(String pk) {
        this.pk = pk;
    }

    public String getCd() {
        return cd;
    }

    public void setCd(String cd) {
        this.cd = cd;
    }

    public String getNa() {
        return na;
    }

    public void setNa(String na) {
        this.na = na;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        BaseIndex other = (BaseIndex) that;
        return (this.getPk() == null ? other.getPk() == null : this.getPk().equals(other.getPk()))
            && (this.getCd() == null ? other.getCd() == null : this.getCd().equals(other.getCd()))
            && (this.getNa() == null ? other.getNa() == null : this.getNa().equals(other.getNa()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getPk() == null) ? 0 : getPk().hashCode());
        result = prime * result + ((getCd() == null) ? 0 : getCd().hashCode());
        result = prime * result + ((getNa() == null) ? 0 : getNa().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append(", pk=").append(pk);
        sb.append(", cd=").append(cd);
        sb.append(", na=").append(na);
        sb.append("]");
        return sb.toString();
    }
}